package com.bo.baby2.dao;

import com.bo.baby2.entity.LogingLogGet;
import com.bo.baby2.entity.TRepayment;
import org.apache.ibatis.annotations.Param;

import java.util.List;


/**
* @program: baby2_p2p
*
* @description: ${description}
*
* @author:波
*
* @create: 2020-07-14 21:18
**/


public interface TRepaymentMapper {
    int deleteByPrimaryKey(String id);

    int insert(TRepayment record);

    int insertSelective(TRepayment record);

    TRepayment selectByPrimaryKey(String id);

    List<TRepayment> getTRepaymentList(String id);

    int updateByPrimaryKeySelective(TRepayment record);

    int updateByPrimaryKey(TRepayment record);

    /**
     * 根据借款Id查询还款信息
     * @param borrowId
     * @return
     */
    List<TRepayment> getRepaymentsByborrowId(String borrowId);

    /**
     * 还款记录查询
     * @param logingLogGet
     * @return
     */
    List<TRepayment> getRepayments(LogingLogGet logingLogGet);

    /**
     * 查询总数量
     * @param logingLogGet
     * @return
     */
    int getCount(LogingLogGet logingLogGet);

    TRepayment getRepaymentById(@Param("Id")String id,@Param("period")Integer period);
}
